home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The CICA Windows Explosion!
/
The CICA Windows Explosion! - Disc 2.iso
/
programr
/
mathstud.zip
/
RANK.M
< prev
next >
Wrap
Text File
|
1993-03-23
|
248b
|
13 lines
function rv = rank(x,tol)
%rv=rank(x,tol)
%computes the rank of the matrix x (using SVD)
% S.Halevy 7/31/92
% Copyright (c) 1992 by the MathWizards
s = svd(x);
if nargin<2
tol=max(size(x))*s(1)*eps;
end
rv=sum(s>tol);